package cn.com.bdqn.dao;

import cn.com.bdqn.entity.SyArea;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface SyAreaDao {

    @Select("select * from sy_area")
    public List<SyArea> queryAll();

    @Insert("insert into sy_area values\n" +
            "(default,#{areaName},#{remark},0)")
    public int addSyArea(SyArea syArea);

    public int updateSyArea(SyArea syArea);

    @Delete("delete from sy_area where id = #{value}")
    public int delSyArea(Long id);

    @Select("select * from sy_area where id = #{value}")
    public SyArea queryById(Long id);

}
